import {post} from '@/util/axios.js'
import {fetchUser} from '@/components/userInfo.js'



export function uploadFile(blob, url) {
    let newIcon = new File([blob], 'newIcon.jpeg', {type: 'image/jpeg'})
    console.log(newIcon)
    post(url, {file: newIcon}, async content => {
        await fetchUser()
    })
}

export function getFile(blob){
    return blob
}